<template>
  <div class="userinfo-hotforum">
    <div class="user-info">
      <div class="photo a flex-yc">
        <img src="" />
        <span>{{ userStore.userInfo.nickName }}</span>
      </div>
      <div class="dianzan flex-yc">
        <div class="flex-y flex-xyc">
          <span>获赞</span>
          <p>{{ userStore.userInfo.likeCount }}</p>
        </div>
        <div class="flex-y flex-xyc">
          <span>发帖</span>
          <p>{{ userStore.userInfo.postCount }}</p>
        </div>
      </div>
    </div>
    <div class="hot-content">
      <h2>推荐用户</h2>
      <div class="con">
        <div class="item flex-yc a" v-for="i in 6" :key="i">
          <img src="" />
          <div class="flex-y flex-xc">
            <span>张文吉</span>
            <p>233赞 · 118帖子</p>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script setup lang="ts">
import { useUserStore } from '@/store/modules/user.ts'

const userStore = useUserStore()
console.log(userStore, 'uersss')
</script>

<style scoped lang="scss">
.userinfo-hotforum {
  width: 220px;

  .user-info {
    background-color: #fff;
    border-radius: 4px;

    .photo {
      padding: 20px 24px;
      border-bottom: 1px solid #f2f2f2;

      > img {
        width: 44px;
        height: 44px;
        margin-right: 13px;
        background-color: #f2f2f2;
        border-radius: 50%;
      }

      > span {
        font-size: 16px;
        font-weight: 500;
        color: #333;
      }
    }

    .dianzan {
      padding: 22px 0;

      .flex-y {
        flex: 1;
        font-size: 14px;
        font-weight: 500;
        color: #333;

        & + .flex-y {
          border-left: 1px solid $borderCol;
        }

        span {
          margin-bottom: 10px;
          font-weight: 400;
          color: #909090;
        }
      }
    }
  }

  .hot-content {
    padding: 0 9px;
    margin-top: 20px;
    background-color: #fff;
    border-radius: 4px;

    > h2 {
      padding: 18px 0 10px;
      font-size: 14px;
      font-weight: 400;
    }

    .con {
      .item {
        padding: 16px 0;
        border-top: 1px solid #f2f2f2;

        img {
          width: 36px;
          height: 36px;
          margin-right: 9px;
          background-color: #d9d9d9;
          border-radius: 50%;
        }

        .flex-y {
          font-size: 14px;
          font-weight: 400;
          color: #333;

          p {
            margin-top: 5px;
            font-size: 12px;
            color: #76797e;
          }
        }
      }
    }
  }
}
</style>
